    <div id="breadcrumbs"><?php echo $this->Html->link('Home', array('controller' => 'contents', 'action' => 'view', 'home')); ?> > <?php echo $this->Html->link('List Questionnaires', array('controller'=>'Questionnaires', 'action'=>'index'));?> > <?php echo $questionnaire['Questionnaire']['qName']?> 
</div>

<div class="questionnaires view">
<h2><?php  echo __('Questionnaire'); ?></h2>
<table>
    <tr>
        <td>
            <?php echo __('Questionnaire'); ?>
        </td>
        <td>
            <?php echo h($questionnaire['Questionnaire']['qName']); ?>
			&nbsp;
        </td>
    </tr>
</table>
<div class="related">
	<h3><?php echo __('Questions'); ?></h3>
	<?php if (!empty($questionnaire['Question'])): ?>
	<table cellpadding = "0" cellspacing = "0">
	<tr>		
		<th><?php echo __('Question'); ?></th>
		<th>View</th>
                <th>Edit</th>
                <th>Delete</th>
	</tr>
	<?php
		$i = 0;
		foreach ($questionnaire['Question'] as $question): ?>
		<tr>
			<td><?php echo $question['questions']; ?></td>
                        <td><?php echo $this->Html->image('view.png',array('alt'=>'View','url'=>array('controller' => 'questions', 'action' => 'view', $question['questions_id']))); ?></td>
                        <td><?php echo $this->Html->image('edit.png',array('alt'=>'Edit','url'=>array('controller' => 'questions', 'action' => 'edit', $question['questions_id']))); ?></td>
                        <td><?php echo $this->Form->postLink($this->Html->image('delete.png', array('alt'=>__('Delete'))), array('controller' => 'questions', 'action' => 'delete', $question['questions_id']), array('escape' =>false, 'confirm' =>__('Are you sure you want to delete '. $question['questions']. '?'))); ?></td>
		
                </tr>
	<?php endforeach; ?>
                
	</table>
<?php endif; ?>
        
                   
</div>
</div>
<div class="actions">
	<h3><?php echo __('Actions'); ?></h3>
	<ul>
		<li><?php echo $this->Html->link(__('Edit Questionnaire'), array('action' => 'edit', $questionnaire['Questionnaire']['q_id'])); ?> </li>
		<li><?php echo $this->Form->postLink(__('Delete Questionnaire'), array('action' => 'delete', $questionnaire['Questionnaire']['q_id']), null, __('Are you sure you want to delete %s?', $questionnaire['Questionnaire']['qName'])); ?> </li>
                <li><?php echo $this->Html->link(__('List Questionnaires'), array('action' => 'index')); ?> </li>
                <li><?php echo $this->Html->link('Add new question',array('controller'=>'questions','action'=>'add'));?></li>
	
        </ul>
</div>

	